<div style="margin:0 auto;width:100%;">
<?php 
    if (isset($this->previous)){
          echo '<a href="#" onclick="loadPage('.$this->previous.')"> &lt; Previous</a> | ';
    }
    foreach ($this->pagesInRange as $page){
       if ($page != $this->current){
               echo  '<a href="#" onclick="loadPage('.$page.')">' . $page . '</a> | ';
      }else{
          echo $page . ' | ';
      }
   }
     if (isset($this->next)){
        echo '<a href="#" onclick="loadPage('.$this->next.')">Next &gt;</a>';
       }
  ?>
</div>